package me.alide.modules.sys.controller;

import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
public class PageController {

    @GetMapping("login.html")
    public String login() {
        return "login";
    }

    @RequestMapping("index.html")
    public String index() {
        return "index";
    }

    @RequestMapping(value = "sys.html")
//    @RequiresPermissions("sys/sys")
    public String dashboard() {
        return "sys/sys";
    }


    @RequestMapping(value = "sys/user.html")
//    @RequiresPermissions("sys/user")
    public String user() {
        return "sys/user";
    }

    @RequestMapping(value = "sys/role.html")
//    @RequiresPermissions("sys/role")
    public String role() {
        return "sys/role";
    }

    @RequestMapping(value = "sys/menu.html")
//    @RequiresPermissions("sys/menu")
    public String menu() {
        return "sys/menu";
    }


    @RequestMapping(value = "sys/menu-add.html")
//    @RequiresPermissions("sys/menu-add")
    public String addMenu() {
        return "sys/menu-add";
    }

    @RequestMapping(value = "sys/menu-edit.html")
//    @RequiresPermissions("sys/menu-edit")
    public String editMneu() {
        return "sys/menu-edit";
    }

    @RequestMapping(value = "sys/user-add.html")
//    @RequiresPermissions("sys/user-add")
    public String userAdd() {
        return "sys/user-add";
    }

    @RequestMapping(value = "sys/user-edit.html")
//    @RequiresPermissions("sys/user-edit")
    public String userEdit() {
        return "sys/user-edit";
    }

    @RequestMapping(value = "sys/role-add.html")
//    @RequiresPermissions("sys/role-add")
    public String roleAdd() {
        return "sys/role-add";
    }

    @RequestMapping(value = "sys/role-edit.html")
//    @RequiresPermissions("sys/role-edit")
    public String roleEdit() {
        return "sys/role-edit";
    }

    @RequestMapping(value = "sys/log.html")
//    @RequiresPermissions("sys/log")
    public String log() {
        return "sys/log";
    }

    @RequestMapping(value = "sys/config.html")
//    @RequiresPermissions("sys/config")
    public String config() {
        return "sys/config";
    }

    @RequestMapping(value = "sys/config-add.html")
//    @RequiresPermissions("sys/config-add")
    public String configAdd() {
        return "sys/config-add";
    }

    @RequestMapping(value = "sys/config-edit.html")
//    @RequiresPermissions("sys/config-edit")
    public String configEdit() {
        return "sys/config-edit";
    }


    @RequestMapping("sys/dept.html")
//    @RequiresPermissions("sys/dept")
    public String dept() {
        return "sys/dept";
    }

    @RequestMapping("sys/dept-add.html")
//    @RequiresPermissions("sys/dept-add")
    public String deptAdd() {
        return "sys/dept-add";
    }

    @RequestMapping("sys/dept-edit.html")
//    @RequiresPermissions("sys/dept-edit")
    public String deptEdit() {
        return "sys/dept-edit";
    }

    @RequestMapping(value = "sys/info.html")
    public String info() {
        return "sys/info";
    }

    @RequestMapping(value = "sys/info-add.html")
    public String saveInfo() {
        return "sys/info-add";
    }

    @RequestMapping(value = "sys/info-edit.html")
    public String updateEdit() {
        return "sys/info-edit";
    }
}
